﻿{layout:default} {class:Shop.Admin.agent.config}
<lbhead>
    <title>
        <%=Tag("参数设置") %>-<%=Tag("代理")%>-<%=site.title%></title>
</lbhead>
<lbpath>
    <div class="tools">
        <ul>
            <%if (PageReturnMsg == ""){%>
            <li class="submit"><a href="javascript:void(0);" onclick="SaveObj();"><b></b><span><%=Tag("保存")%></span></a></li>
            <%}%>
            <li class="name"><span id="navIgation">
                <%=Tag("当前位置")%>：<a href="<%=site.AdminPath %>/Ajax/ajax_admin.aspx?__Action=MenuJump&pid=0"><%=Tag("管理首页")%></a>
                >
                <%=Tag("参数设置")%></span></li>
        </ul>
    </div>
</lbpath>
<lbbody>
    <table
        id="common" class="table">
        <tbody>
            <tr>
                <th>
                    <%=Tag("推广功能")%>：
                </th>
                <td>
                    <input type="radio" name="IsUsedAgent" value="1" shop="true" <%=model.IsUsedAgent=="1"?"checked":"" %> /><%=Tag("开启")%>
                    <input type="radio" name="IsUsedAgent" value="0" shop="true" <%=model.IsUsedAgent=="0"?"checked":"" %> /><%=Tag("关闭")%>
                </td>
            </tr>
            <%-- 
            <tr>
                <th>
                    <%=Tag("地区代理")%>：
                </th>
                <td>
                    <input type="radio" name="IsUsedAgent_Area" value="1" shop="true" <%=model.IsUsedAgent_Area=="1"?"checked":"" %> /><%=Tag("开启")%>
                    <input type="radio" name="IsUsedAgent_Area" value="0" shop="true" <%=model.IsUsedAgent_Area=="0"?"checked":"" %> /><%=Tag("关闭")%>
                </td>
            </tr>
            <tr>
                <th>
                    <%=Tag("商品代理")%>：
                </th>
                <td>
                    <input type="radio" name="IsUsedAgent_Product" value="1" shop="true" <%=model.IsUsedAgent_Product=="1"?"checked":"" %> /><%=Tag("开启")%>
                    <input type="radio" name="IsUsedAgent_Product" value="0" shop="true" <%=model.IsUsedAgent_Product=="0"?"checked":"" %> /><%=Tag("关闭")%>
                </td>
            </tr>
            <tr>
                <th style="vertical-align:top">
                    <%=Tag("过期可续费天数")%>：
                </th>
                <td>
                    <input onkeyup="value=value.replace(/[^\d]/g,'');" type="text" id="AgentEndDays"
                        name="AgentEndDays" value="<%=model.AgentEndDays %>" class="input" style="width: 100px;"
                        shop="true" /> <em>天</em>
                </td>
            </tr>
            <tr>
                <th style="vertical-align:top">
                    <%=Tag("附加佣金")%>：
                </th>
                <td>
                    <em>佣金收入达到</em>
                    <input onkeyup="value=value.replace(/[^\d\.]/g,'');" type="text" id="Angent_Commission"
                        name="Angent_Commission" value="<%=model.Angent_Commission %>" class="input" style="width: 100px;"
                        shop="true" />
                    <em>可享受1级+2级佣金百分比</em>
                    <input onkeyup="value=value.replace(/[^\d\.]/g,'');" type="text" id="Angent_Commission_require"
                        name="Angent_Commission_require" value="<%=model.Angent_Commission_require %>" class="input" style="width: 100px;"
                        shop="true" /> <em></em>

                </td>
            </tr>
            --%>
            <tr>
                <th style="vertical-align:top">
                    <%=Tag("佣金冻结天数")%>：
                </th>
                <td>
                    <input onkeyup="value=value.replace(/[^\d]/g,'');" type="text" id="CommissionMoneyDays"
                        name="CommissionMoneyDays" value="<%=model.CommissionMoneyDays %>" class="input" style="width: 100px;"
                        shop="true" /> <em>天</em>
                </td>
            </tr>
            <tr>
                <th style="vertical-align:top">
                    <%=Tag("一级佣金")%>：
                </th>
                <td>
                    <input onkeyup="value=value.replace(/[^\d\.]/g,'');" type="text" id="Angent1_Commission"
                        name="Angent1_Commission" value="<%=model.Angent1_Commission %>" class="input" style="width: 100px;"
                        shop="true" /> <em><%=Tag("订单商品利润金额")%>%</em>
                </td>
            </tr>
            <tr>
                <th style="vertical-align:top">
                    <%=Tag("二级佣金")%>：
                </th>
                <td>
                    <input onkeyup="value=value.replace(/[^\d\.]/g,'');" type="text" id="Angent2_Commission"
                        name="Angent2_Commission" value="<%=model.Angent2_Commission %>" class="input" style="width: 100px;"
                        shop="true" /> <em><%=Tag("订单商品利润金额")%>%</em>
                </td>
            </tr>
            <tr>
                <th style="vertical-align:top">
                    <%=Tag("三级佣金")%>：
                </th>
                <td>
                    <input onkeyup="value=value.replace(/[^\d\.]/g,'');" type="text" id="Angent3_Commission"
                        name="Angent3_Commission" value="<%=model.Angent3_Commission %>" class="input" style="width: 100px;"
                        shop="true" /> <em><%=Tag("订单商品利润金额")%>%</em>
                </td>
            </tr>
        </tbody>
    </table>

    <script type="text/javascript">
        function SaveObj() {
            var postData = GetFormJsonData("shop");
            var url="<%=site.AdminPath %>/ajax/ajax_agent.aspx?__Action=AgentConfig_Set";
            RequestAjax(url,postData,function(res){MsgBox(1, "<%=Tag("操作成功")%>", "")});
        }
        
    </script>
</lbbody>
<lbbottom>
    <input type="hidden" id="pwd" runat="server" />
</lbbottom>
